home *** CD-ROM | disk | FTP | other *** search
/ The Fatted Calf / The Fatted Calf.iso / Applications / Audio / GISO / Source / Defaults.h < prev    next >
Text File  |  1992-11-07  |  2KB  |  73 lines

  1. /*    
  2. **    Copyright (C) 1992  Ronin Consulting, Inc.
  3. **
  4. **    This program is free software; you can redistribute it and/or modify
  5. **    it under the terms of the GNU General Public License as published by
  6. **    the Free Software Foundation; version 1.
  7. **
  8. **    This program is distributed in the hope that it will be useful,
  9. **    but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. **    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  11. **    GNU General Public License for more details.
  12. **
  13. **    You should have received a copy of the GNU General Public License
  14. **    along with this program; if not, write to the Free Software
  15. **    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  16. */
  17.  
  18. /* 
  19. ** This object is designed to simplyfy the use of the NeXT defaults facilities.
  20. **
  21. */
  22.  
  23. #import <objc/Object.h>
  24. #import <defaults/defaults.h>
  25.  
  26. @interface Defaults : Object
  27. {
  28.    const char *appName;
  29.    BOOL registered;
  30. }
  31.  
  32. /*
  33. ** This is a shared object so allocate it with new.
  34. */
  35. + new;
  36.  
  37. /*
  38. ** Register a defaults vector. If no vector is registered before a get/set (or any other) call is
  39. ** used then an empty vector is used.
  40. */
  41. - regDefaults: (NXDefaultsVector) defaultsVector; 
  42.  
  43. /*
  44. ** Get/Set a default.
  45. */
  46. - (const char *) get: (char *) aDefault;
  47. - set: (char *) aDefault to: (char *)aValue;
  48.  
  49. /*
  50. ** Get/Set that Ignore the cached values and use the actual database.
  51. */
  52. - (const char *) readDB: (char *) aDefault;
  53. - writeDB: (char *) aValue as: (char *)aValue;
  54.  
  55. /*
  56. ** Remove a default from the database.
  57. */
  58. - remove: (char *) aDefault;
  59.  
  60. /*
  61. ** Write a cached default out to the file.
  62. */
  63. - update: (char *) aDefault;
  64.  
  65. /*
  66. ** Update ALL cached values.
  67. */
  68. - update;
  69.  
  70. @end
  71.  
  72.  
  73.